package com.lynn.salary.service;

import java.util.List;
import java.util.Map;

import com.lynn.salary.entity.Article;
import com.lynn.salary.entity.BaseEntity;

public interface IBaseEntityService {

	public <T> T save(T t) throws Exception;

	public <T extends BaseEntity> boolean delete(String[] ids, T t) throws Exception;

	public <T> T getByPk(String id, Class<T> t) throws Exception;

	public <T> boolean update(Map<String, Object> data, Class<T> t) throws Exception;

	public <T> List<Map<String, Object>> getPartByCondition(Class<T> c, String[] part, String condition) throws Exception;

	public <T extends BaseEntity> boolean addTag(String[] ids, String tag, T t) throws Exception;

	public <T extends BaseEntity> boolean removeTag(String[] ids, String tag, T t) throws Exception;

	public <T> List<Map<String, Object>> getPartByCondition(Class<T> clazz, String[] strings, String string, Object... values) throws Exception;
}
